Filter hook 'customize_validate_{$this->id}'
in WP Core File wp-includes/class-wp-customize-setting.php at line 612
Description
Validates a Customize setting value. Plugins should amend the `$validity` object via its `WP_Error::add()` method. The dynamic portion of the hook name, `$this->ID`, refers to the setting ID.
Occurrences
Filename |
Line Number |
wp-includes/class-wp-customize-setting.php |
612 |
Parameters
Type |
Name |
Description |
WP_Error |
$validity |
Filtered from `true` to `WP_Error` when invalid. |
mixed |
$value |
Value of the setting. |
WP_Customize_Setting |
$setting |
WP_Customize_Setting instance. |
PHP Doc
/**
* Validates a Customize setting value.
*
* Plugins should amend the `$validity` object via its `WP_Error::add()` method.
*
* The dynamic portion of the hook name, `$this->ID`, refers to the setting ID.
*
* @since 4.6.0
*
* @param WP_Error $validity Filtered from `true` to `WP_Error` when invalid.
* @param mixed $value Value of the setting.
* @param WP_Customize_Setting $setting WP_Customize_Setting instance.
*/